<extend name="work/base"/>
<block name="content">

    <table class="layui-table text-center" id="list" lay-filter="list"
           list-url="{:url('sys/wechat/lists')}"
    ></table>

</block>
<block name="script">
    <script type="text/javascript">
        layui.use(['element', 'table', 'form', 'tree'], function () {
            var table = layui.table
                , element = layui.element
                , form = layui.form;
            table.render({
                elem: '#list'
                , url: "{:Url('sys/wechat/lists')}"
                , page: true
                , limit: 20
                , cols: [[
                     {field: 'product_run_id', title: '项目id'}
                    , {field: 'authorizer_appid', width: 200, title: 'authorizer_appid'}
                    , {field: 'appid', width: 200, title: 'appid'}
                    , {field: 'update_time', width: 200, title: '最后更新时间'}

                ]]
            });

            form.on('submit(search_btn)', function (data) {
                table.reload('list', {
                    url: "{:Url('sys/minapp/lists')}"
                    , page: {
                        curr: 1
                    }
                    , where: data.field
                });
                return false;
            });

        });
    </script>
</block>